const targetObj = { name: 'henry' }
const proxy = new Proxy(targetObj, {
  get(target, property) {
    console.log(`get： ${property} = ${target[property]}`)
    return Reflect.get(targetObj, property)
  },
  set(target, property, value) {
    console.log(`set： ${property} = ${value}`)
    return Reflect.set(targetObj, property, value)
  }
})

proxy.name //=>get： name = henry
proxy.age = 18 //=>set： age = 18
